<template>
  <div class="app-container">
    <!-- 头部 -->
    <div class="ProductionDynamicHeader">
      <Find :OriginalFilter="{ static: true }" :formList="formList" @findClicked="findData" />
    </div>
    <el-card shadow="never" :body-style="{ padding: '11px 20px' }">
      <div slot="header" class="f16">
        <span style="font-weight: 600">生产动态查询</span>
      </div>
      <Table :tableHeader="tableHeader" :tableData="tableData" :TableHeight="120" class="mt10" />
      <PageModule :PageData="{ pageSizeShow: true }" />
    </el-card>
  </div>
</template>
<script lang="ts">
import { defineComponent, ref } from 'vue'
import JMessage from '@/utils/JMessage'
export default defineComponent({
  name: 'ProductionDynamicAnalysisLc'
})
</script>
<script lang="ts" setup>
import { i18n, Jzhcn } from '@/i18n'
const formList = ref([
  {
    type: 'date',
    dateLabel: '日期',
    dateValue: ''
  },
  {
    type: 'button',
    checkboxLabel: '生成生产动态表'
  },
  {
    type: 'input',
    inputLabel: '核算日期',
    inputDisabled: true,
    inputValue: '颜色/景色'
  },
  {
    type: 'date',
    dateLabel: '请输入指令',
    dateValue: ''
  },
  {
    type: 'date',
    dateLabel: '请输入型体',
    dateValue: ''
  },
  {
    type: 'date',
    dateLabel: '请输入客户',
    dateValue: ''
  },
  {
    type: 'select',
    selectValue: '线别',
    selectLabel: '',
    selectOptions: [
      {
        optionKey: '1',
        optionValue: '111111',
        optionLabel: 'option1'
      },
      {
        optionKey: '2',
        optionValue: '222222',
        optionLabel: 'option2'
      },
      {
        optionKey: '3',
        optionValue: '333333',
        optionLabel: 'option3'
      }
    ]
  },
  {
    type: 'date',
    dateLabel: '交期',
    dateValue: ''
  },
  {
    type: 'select',
    selectValue: '下单',
    selectLabel: '',
    selectOptions: [
      {
        optionKey: '1',
        optionValue: '111111',
        optionLabel: 'option1'
      },
      {
        optionKey: '2',
        optionValue: '222222',
        optionLabel: 'option2'
      },
      {
        optionKey: '3',
        optionValue: '333333',
        optionLabel: 'option3'
      }
    ]
  },
  {
    type: 'select',
    selectValue: '季度',
    selectLabel: '',
    selectOptions: [
      {
        optionKey: '1',
        optionValue: '111111',
        optionLabel: 'option1'
      },
      {
        optionKey: '2',
        optionValue: '222222',
        optionLabel: 'option2'
      },
      {
        optionKey: '3',
        optionValue: '333333',
        optionLabel: 'option3'
      }
    ]
  },
  {
    type: 'date',
    dateLabel: '请输入客人货号',
    dateValue: ''
  },
  {
    type: 'checkbox',
    checkboxLabel: '已结束',
    checked: true
  },
  {
    type: 'checkbox',
    checkboxLabel: '未结束',
    checked: false
  },
  {
    type: 'checkbox',
    checkboxLabel: '全部',
    checked: false
  },
  {
    type: 'button',
    checkboxLabel: '导出生产动态表'
  },
  {
    type: 'button',
    checkboxLabel: '导出生产周期表'
  },
  {
    type: 'button',
    checkboxLabel: '时辰门槛定义'
  },
  {
    type: 'input',
    inputLabel: '客人货号',
    inputDisabled: true,
    inputValue: '颜色/景色'
  },
  {
    type: 'input',
    inputLabel: '季度',
    inputDisabled: true,
    inputValue: '颜色/景色'
  },
  {
    type: 'button',
    checkboxLabel: '标注指令已结束'
  },
  {
    type: 'button',
    checkboxLabel: '查询标注结束指令'
  }
])
const findData = (data: any) => {
  console.log(data)
}
// 表格数据
const tableData = [
  {
    date: '20230427',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-02',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-04',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  },
  {
    date: '2016-05-01',
    name: 'Tom',
    address: '12312'
  }
]

const tableHeader = ref([
  {
    label: '客户',
    prop: 'instruction'
  },
  {
    label: '指令',
    prop: 'shape'
  },
  {
    label: '型体',
    prop: 'shape'
  },
  {
    label: '配色',
    prop: 'shape'
  },
  {
    label: '订单号',
    prop: 'shape'
  },
  {
    label: '预补量',
    prop: 'shape'
  },
  {
    label: '下单日期',
    prop: 'shape'
  },
  {
    label: '客户交期',
    prop: 'shape'
  },
  {
    Multistage: true,
    label: '斩刀试作',
    children: [
      {
        label: '计划日期',
        prop: 'j'
      },
      {
        label: '实际日期',
        prop: 'z'
      }
    ]
  },
  {
    label: '欠料',
    prop: 'shape'
  },
  {
    Multistage: true,
    label: '主面料',
    children: [
      {
        label: '计划日期',
        prop: 'j'
      },
      {
        label: '实际日期',
        prop: 'z'
      }
    ]
  },
  {
    Multistage: true,
    label: '冲裁',
    children: [
      {
        label: '冲裁组别',
        prop: 'j'
      },
      {
        label: '裁断当日',
        prop: 'z'
      },
      {
        label: '裁断欠数',
        prop: 'z'
      },
      {
        label: '计划完成',
        prop: 'z'
      },
      {
        label: '实际完成',
        prop: 'z'
      }
    ]
  },
  {
    Multistage: true,
    label: '工艺',
    children: [
      {
        label: '工艺欠数',
        prop: 'customer'
      },
      {
        label: '计划完成',
        prop: 'customer'
      },
      {
        label: '实际完成',
        prop: 'customer'
      }
    ]
  },
  {
    Multistage: true,
    label: '配套',
    children: [
      {
        label: '配套当日',
        prop: 'shape'
      },
      {
        label: '配套欠数',
        prop: 'shape'
      }
    ]
  }
])

// 表格数据
const tableData1 = [
  {
    customer: '张三',
    instruction: '李四',
    shape: '王五',
    j: '132',
    z: '666'
  }
]
const tableHeader1 = ref([
  {
    Multistage: true,
    label: '冲裁',
    children: [
      {
        label: '冲裁组别',
        prop: 'j'
      },
      {
        label: '裁断当日',
        prop: 'z'
      },
      {
        label: '裁断欠数',
        prop: 'z'
      },
      {
        label: '计划完成',
        prop: 'z'
      },
      {
        label: '实际完成',
        prop: 'z'
      }
    ]
  },
  {
    Multistage: true,
    label: '工艺',
    children: [
      {
        label: '工艺欠数',
        prop: 'customer'
      },
      {
        label: '计划完成',
        prop: 'customer'
      },
      {
        label: '实际完成',
        prop: 'customer'
      }
    ]
  },
  {
    Multistage: true,
    label: '配套',
    children: [
      {
        label: '配套当日',
        prop: 'shape'
      },
      {
        label: '配套欠数',
        prop: 'shape'
      }
    ]
  },
  {
    Multistage: true,
    label: '针车',
    children: [
      {
        label: '针车组别',
        prop: 'shape'
      },
      {
        label: '当日产量',
        prop: 'shape'
      },
      {
        label: '针车欠数',
        prop: 'shape'
      },
      {
        label: '计划完成',
        prop: 'shape'
      },
      {
        label: '实际完成',
        prop: 'shape'
      }
    ]
  },
  {
    Multistage: true,
    label: '鞋面仓',
    children: [
      {
        label: '库存',
        prop: 'shape'
      }
    ]
  },
  {
    Multistage: true,
    label: '大底',
    children: [
      {
        label: '大底厂商',
        prop: 'shape'
      },
      {
        label: '当日入库',
        prop: 'shape'
      }
    ]
  },
  {
    Multistage: true,
    label: '鞋垫',
    children: [
      {
        label: '欠数',
        prop: 'shape'
      }
    ]
  },
  {
    Multistage: true,
    label: '成型投料',
    children: [
      {
        label: '成型组别',
        prop: 'shape'
      },
      {
        label: '当日投料',
        prop: 'shape'
      },
      {
        label: '投料欠数',
        prop: 'shape'
      },
      {
        label: '计划完成',
        prop: 'shape'
      },
      {
        label: '实际完成',
        prop: 'shape'
      }
    ]
  },
  {
    Multistage: true,
    label: '成型产出',
    children: [
      {
        label: '当日产出',
        prop: 'shape'
      },
      {
        label: '欠数',
        prop: 'shape'
      },
      {
        label: '计划完成',
        prop: 'shape'
      },
      {
        label: '实际完成',
        prop: 'shape'
      }
    ]
  }
])
</script>

<style lang="less" scoped>
:deep(.ProductionDynamicMainCardBottom .el-input__wrapper) {
  background-color: #fff5eb;
}

.save {
  color: black;
  border: 1px solid #e7e7e7;
  background: #e7e7e7;
}
</style>
